use crate::worker::worker_core::Worker;
use crate::worker::message::Message;
use anyhow::Result;

/// 结合tokio基本调度器能使用的CSP模型编程

pub trait Handler<M>
    where
        Self: Worker,
        M: Message,
{
    fn handle(&mut self, msg: M)->Result<()>;
}
